package com.hy.dubboprovider.Controller;

import com.hy.common.Service.UserService;
import com.hy.common.pojo.User;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author: 王富贵
 * @description:
 * @createTime: 2022年10月04日 19:58:50
 */

@RestController
public class UserController {
    @Resource
    private UserService userService;

    @GetMapping("/user/{id}")
    public User getUser(@PathVariable("id")Integer id){
        return userService.getUser(id);
    }
}
